package com.gxc.service.goods.model.entity;

import com.gxc.service.common.model.entity.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.math.BigDecimal;

/**
 * 商品基本信息
 *
 * @author GongXincheng
 * @date 2019/10/15 13:44
 */
@Data
@Entity
@Table(name = "pm_product")
@EqualsAndHashCode(callSuper = true)
public class ProductEntity extends BaseEntity {

    /**
     * 产品名称
     */
    @Column(name = "prod_name", columnDefinition = "varchar")
    private String prodName;

    /**
     * 店铺 id
     */
    @Column(name = "shop_id", columnDefinition = "bigint")
    private Long shopId;

    /**
     * 锐锢 sku code
     */
    @Column(name = "sku_code", columnDefinition = "char")
    private String skuCode;

    /**
     * 显示的名称
     */
    @Column(name = "display_name", columnDefinition = "varchar")
    private String displayName;

    /**
     * 型号
     */
    @Column(name = "model", columnDefinition = "varchar")
    private String model;

    /**
     * 品牌ID
     */
    @Column(name = "brand_id", columnDefinition = "bigint")
    private Long brandId;

    /**
     * 排序
     */
    @Column(name = "sort", columnDefinition = "int")
    private Integer sort;

    /**
     * 图片地址
     */
    @Column(name = "image", columnDefinition = "varchar")
    private String image;

    /**
     * 单位
     */
    @Column(name = "unit", columnDefinition = "varchar")
    private String unit;

    /**
     * 销售价格
     */
    @Column(name = "sale_price", columnDefinition = "decimal")
    private BigDecimal salePrice;

    /**
     * 显示价格
     */
    @Column(name = "display_price", columnDefinition = "decimal")
    private BigDecimal displayPrice;

    /**
     * 采购价格, 小工无法看到
     */
    @Column(name = "purchase_price", columnDefinition = "decimal")
    private BigDecimal purchasePrice;

    /**
     * 市场参考价
     */
    @Column(name = "market_refer_price", columnDefinition = "decimal")
    private BigDecimal marketReferPrice;

    /**
     * 标签详情
     */
    @Column(name = "tags", columnDefinition = "varchar")
    private String tags;

    /**
     * 备注
     */
    @Column(name = "remark", columnDefinition = "varchar")
    private String remark;

}
